﻿<span class="col_title">Recent Works</span>
        <table class="job_list" width="100%">
            <thead>
                <th width="30%">Project Name</th>
                <th width="15%">Type</th>
                <th width="5%">Bid(s)</th>
                <th width="10%">Khoảng tiền</th>
                <th width="30%">Skills Required</th>
                <th width="5%">Start</th>
                <th width="5%">End</th>
            </thead>
            <tbody>
			<?php 
				foreach ($model as $key):
					$countBid = Bidjob::model()->countByAttributes(array('job_id'=>$key->id));
			?> 
                <tr>
                    <td><?php echo CHtml::link(substr($key->name, 0, 50), array('job/view', 'id'=>$key->id)); ?></td>
                    <td>
						<?php					
							echo $post->getJob($key->subjobtype_id);
						?>
					</td>
                    <td><?php echo $countBid; ?></td>

                    <td><?php echo $key->budget->money;?></td>

                    <td><?php echo $key->skillsrequired;?></td>
                    <td>Today</td>
                    <td>5days</td>
                </tr>
			<?php endforeach; ?>
            </tbody>
        </table>
		<?php //if(!isset($_GET['search'])) 
			$this->widget("CLinkPager", array('pages'=>$page));
		?>
